import java.util.Scanner;

public class Java2 {
//在同一个类中,分别定义求两个整数的方法 和 三个小数之和的方法。 并执行代码，求出结果
public static int main1(int num1,int num2) {
    return num1 + num2;

}

    public static double main2(double sum1,double sum2,double sum3) {
    return sum1 + sum2 +sum3;

    }

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int num1 = scanner.nextInt();
        int num2 = scanner.nextInt();
        double sum1 = scanner.nextDouble();
        double sum2 = scanner.nextDouble();
        double sum3 = scanner.nextDouble();
        int Num = main1(num1,num2);
        System.out.println(Num);
        double Sum = main2(sum1,sum2,sum3);
        System.out.println(Sum);
    }
}
